package com.pimwi.dp
{
  import com.pimwi.vo.Group;
  
  import flash.events.Event;
  import flash.events.EventDispatcher;

  public class GroupDP extends EventDispatcher
  {
    private var _group:Group;

    public function GroupDP(group:Group = null)
    {
      _group = group;
      dispatchEvent(new Event("groupChanged"));
    }

    [Bindable("groupChanged")]
    public function get group():Group
    {
      return _group;
    }
    public function set group(value:Group):void
    {
      _group = value;
      dispatchEvent(new Event("groupChanged"));
    }

    [Bindable("groupChanged")]
    [Bindable("idChanged")]
    public function get id():int
    {
      return _group.id;
    }
    public function set id(value:int):void
    {
      _group.id = value;
      dispatchEvent(new Event("idChanged"));
    }

    [Bindable("groupChanged")]
    [Bindable("nameChanged")]
    public function get name():String
    {
      return _group.name;
    }
    public function set name(value:String):void
    {
      _group.name = value;
      dispatchEvent(new Event("nameChanged"));
    }

  }
}